package com.ytjj.qmyx.admin.dao;

import com.ytjj.qmyx.admin.model.request.LogisticsRequest;
import com.ytjj.qmyx.admin.model.response.ReissueLogisticsExportResponse;
import com.ytjj.qmyx.admin.model.response.ReissueLogisticsResponse;
import com.ytjj.qmyx.mall.model.ReissueLogistics;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.Date;
import java.util.List;

@Repository
public interface ReissueLogisticsDao {

    List<ReissueLogisticsResponse> getReissueLogisticsList(LogisticsRequest logisticsRequest);

    List<ReissueLogisticsExportResponse> getReissueLogisticsExportList(LogisticsRequest logisticsRequest);

    Integer insertLogistics(ReissueLogistics reissueLogistics);

    Integer updateStatus(@Param("id") Integer id, @Param("operationTime")Date operationTime);

    Integer updateDeleteStatus(@Param("id") Integer id);

    Integer getStatus(String orderNo);

    Integer delReissueLogistics(Integer id);

    Integer updateExportStatus(Integer id);

    boolean updatefinishStatus(Integer id,Date finishTime);

    List<ReissueLogistics> selectByChildOrderNo(String childOrderNo);

    List<ReissueLogistics> selectByChildOrderNoList(@Param("childOrderNoList") List<String> childOrderNoList);

    ReissueLogistics selectById(@Param("id") Integer id);

    /**
     * 修改补单信息为是否已完结
     */
    int  updateReissueLogisticsFished(@Param("id") Integer id,@Param("finishStatus") Integer finishStatus,
                                      @Param("reissueStatus")Integer reissueStatus,@Param("finishTime")Date finishTime);
}
